﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using Models;

namespace PcBackgroundMgr.Functions
{
    /// <summary>
    /// EnterpriseListCtrl.xaml 的交互逻辑
    /// </summary>
    public partial class EnterpriseListCtrl : ExhibitListCtrl
    {
        public EnterpriseListCtrl()
            : base(typeof(EnterpriseModelCtrl))
        {
            InitializeComponent();
        }

        protected override void OnInitializeSingleSearch(Type type)
        {
            //base.OnInitializeSingleSearch(type);
            SingleSearchItems.Add(new SingleSearch("Name", "名称"));
            SingleSearchItems.Add(new SingleSearch("Author", "作者"));
            SingleSearchItems.Add(new SingleSearch("TypeName", "类型"));
            mSqlWhere = " where Class = " + (int)ExhibitClassEnum.企业联盟;
        }

        private void EditableCtrl_MouseDoubleClick(object sender, MouseButtonEventArgs e)
        {
            OnCommandModify((sender as FrameworkElement).DataContext);
        }

    }
}
